3.68 \(\int \frac{(d+e x) (2-x-2 x^2+x^3)}{4-5 x^2+x^4} \, dx\)

Optimal. Leaf size=14 \[ (d-2 e) \log (x+2)+e x \]

[Out]

e*x + (d - 2*e)*Log[2 + x]

________________________________________________________________________________________

Rubi [A]  time = 0.0239435, antiderivative size = 14, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 31, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.065, Rules used = {1586, 43} \[ (d-2 e) \log (x+2)+e x \]

Antiderivative was successfully verified.

[In]

Int[((d + e*x)*(2 - x - 2*x^2 + x^3))/(4 - 5*x^2 + x^4),x]

[Out]

e*x + (d - 2*e)*Log[2 + x]

Rule 1586

Int[(u_.)*(Px_)^(p_.)*(Qx_)^(q_.), x_Symbol] :> Int[u*PolynomialQuotient[Px, Qx, x]^p*Qx^(p + q), x] /; FreeQ[
q, x] && PolyQ[Px, x] && PolyQ[Qx, x] && EqQ[PolynomialRemainder[Px, Qx, x], 0] && IntegerQ[p] && LtQ[p*q, 0]

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin{align*} \int \frac{(d+e x) \left (2-x-2 x^2+x^3\right )}{4-5 x^2+x^4} \, dx &=\int \frac{d+e x}{2+x} \, dx\\ &=\int \left (e+\frac{d-2 e}{2+x}\right ) \, dx\\ &=e x+(d-2 e) \log (2+x)\\ \end{align*}

Mathematica [A]  time = 0.0044482, size = 16, normalized size = 1.14 \[ (d-2 e) \log (x+2)+e (x+2) \]

Antiderivative was successfully verified.

[In]

Integrate[((d + e*x)*(2 - x - 2*x^2 + x^3))/(4 - 5*x^2 + x^4),x]

[Out]

e*(2 + x) + (d - 2*e)*Log[2 + x]

________________________________________________________________________________________

Maple [A]  time = 0.002, size = 18, normalized size = 1.3 \begin{align*} ex+\ln \left ( 2+x \right ) d-2\,\ln \left ( 2+x \right ) e \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((e*x+d)*(x^3-2*x^2-x+2)/(x^4-5*x^2+4),x)

[Out]

e*x+ln(2+x)*d-2*ln(2+x)*e

________________________________________________________________________________________

Maxima [A]  time = 0.948895, size = 19, normalized size = 1.36 \begin{align*} e x +{\left (d - 2 \, e\right )} \log \left (x + 2\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(x^3-2*x^2-x+2)/(x^4-5*x^2+4),x, algorithm="maxima")

[Out]

e*x + (d - 2*e)*log(x + 2)

________________________________________________________________________________________

Fricas [A]  time = 1.73338, size = 38, normalized size = 2.71 \begin{align*} e x +{\left (d - 2 \, e\right )} \log \left (x + 2\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(x^3-2*x^2-x+2)/(x^4-5*x^2+4),x, algorithm="fricas")

[Out]

e*x + (d - 2*e)*log(x + 2)

________________________________________________________________________________________

Sympy [A]  time = 0.263152, size = 12, normalized size = 0.86 \begin{align*} e x + \left (d - 2 e\right ) \log{\left (x + 2 \right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(x**3-2*x**2-x+2)/(x**4-5*x**2+4),x)

[Out]

e*x + (d - 2*e)*log(x + 2)

________________________________________________________________________________________

Giac [A]  time = 1.08089, size = 23, normalized size = 1.64 \begin{align*} x e +{\left (d - 2 \, e\right )} \log \left ({\left | x + 2 \right |}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(x^3-2*x^2-x+2)/(x^4-5*x^2+4),x, algorithm="giac")

[Out]

x*e + (d - 2*e)*log(abs(x + 2))